#ifndef SHADERFACTORY_HPP_
# define SHADERFACTORY_HPP_

#ifdef _MSC_VER
# pragma warning(disable: 4290)
#endif

# include <exception>
# include "Shader.hpp"
# include "CharArray.hpp"

class ShaderFactory
{
public:
	ShaderFactory(void);
	~ShaderFactory(void);

	Shader			create(const char* vertexSource, const char* fragmentSource) throw (std::exception);
	GLuint			compile(const char* source, const GLuint type) throw (std::exception);
	CharArray		loadSource(const char* source) throw (std::exception);
	void			destroy(Shader& shader);
};

#endif // !SHADERFACTORY_HPP_
